package com.ildepinc.persistence.interfaces;

import java.sql.ResultSet;
import java.util.HashMap;

/**
 * All the methods in this interface shall be implemented in a concrete class
 * The exceptions are: getTable, setTable
 */

public interface DaoTableBehaviour<T> extends DaoCommonBehaviour {
  T copyRecordTo();

  Integer doDelete(HashMap<String, Object> primaryKeys) throws Exception;

  Integer doInsert(T record, HashMap<String, Object> primaryKeys) throws Exception;

  T doSelect(HashMap<String, Object> primaryKeys) throws Exception;

  Integer doUpdate(T record) throws Exception;

  T getTable();

  void readRecordFrom(ResultSet resultSet) throws Exception;

  void setTable(T table);
}
